// @ts-ignore
import { api } from '@/utils/api';

/** 新增系统用户数据 POST /orgUserInfo/add */
export async function orgUserInfoAdd(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoAdd(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoAdd(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoAdd(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/add`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/add`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 删除系统用户数据 POST /orgUserInfo/delete */
export async function orgUserInfoDelete(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoDelete(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoDelete(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoDelete(body: BASE.ID, options?: ArgumentsType<typeof api>[1]) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/delete`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/delete`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 获取系统用户VO数据 POST /orgUserInfo/getVo */
export async function orgUserInfoGetVo(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResultOrgUserInfoVOduixiang>;

export async function orgUserInfoGetVo(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResultOrgUserInfoVOduixiang>>;

export async function orgUserInfoGetVo(
  body: BASE.ID,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResultOrgUserInfoVOduixiang>;

export async function orgUserInfoGetVo(body: BASE.ID, options?: ArgumentsType<typeof api>[1]) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResultOrgUserInfoVOduixiang>(`/app/orgUserInfo/getVo`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResultOrgUserInfoVOduixiang>(`/app/orgUserInfo/getVo`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 设置用户部门 POST /orgUserInfo/setDept */
export async function orgUserInfoSetDept(
  body: BASE.AddUserDept,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoSetDept(
  body: BASE.AddUserDept,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoSetDept(
  body: BASE.AddUserDept,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoSetDept(
  body: BASE.AddUserDept,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/setDept`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/setDept`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 设置为主部门 POST /orgUserInfo/setMainDept */
export async function orgUserInfoSetMainDept(
  body: BASE.AutoDtoWithOrguserinfoSetmaindept,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoSetMainDept(
  body: BASE.AutoDtoWithOrguserinfoSetmaindept,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoSetMainDept(
  body: BASE.AutoDtoWithOrguserinfoSetmaindept,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoSetMainDept(
  body: BASE.AutoDtoWithOrguserinfoSetmaindept,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/setMainDept`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/setMainDept`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 更新系统用户数据 POST /orgUserInfo/update */
export async function orgUserInfoUpdate(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoUpdate(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoUpdate(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoUpdate(
  body: BASE.AddUserDTO,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/update`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/update`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 修改头像 POST /orgUserInfo/update/photo */
export async function orgUserInfoUpdatePhoto(
  body: BASE.AutoDtoWithOrguserinfoUpdatePhoto,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoUpdatePhoto(
  body: BASE.AutoDtoWithOrguserinfoUpdatePhoto,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoUpdatePhoto(
  body: BASE.AutoDtoWithOrguserinfoUpdatePhoto,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoUpdatePhoto(
  body: BASE.AutoDtoWithOrguserinfoUpdatePhoto,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/update/photo`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/update/photo`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 用户自己修改基础信息 POST /orgUserInfo/updateBySelf */
export async function orgUserInfoUpdateBySelf(
  body: BASE.SelfUpdateUserDTOduixiang,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoUpdateBySelf(
  body: BASE.SelfUpdateUserDTOduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoUpdateBySelf(
  body: BASE.SelfUpdateUserDTOduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoUpdateBySelf(
  body: BASE.SelfUpdateUserDTOduixiang,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/updateBySelf`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/updateBySelf`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 修改系统用户状态 POST /orgUserInfo/updateState */
export async function orgUserInfoUpdateState(
  body: BASE.AutoDtoWithOrguserinfoUpdatestate,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResult>;

export async function orgUserInfoUpdateState(
  body: BASE.AutoDtoWithOrguserinfoUpdatestate,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResult>>;

export async function orgUserInfoUpdateState(
  body: BASE.AutoDtoWithOrguserinfoUpdatestate,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResult>;

export async function orgUserInfoUpdateState(
  body: BASE.AutoDtoWithOrguserinfoUpdatestate,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResult>(`/app/orgUserInfo/updateState`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResult>(`/app/orgUserInfo/updateState`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 获取系统用户VO列表数据 POST /orgUserInfo/voList */
export async function orgUserInfoVoList(
  body: BASE.OrgUserInfoliebiaochaxunduixiang,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResultListOrgUserInfoVOduixiang>;

export async function orgUserInfoVoList(
  body: BASE.OrgUserInfoliebiaochaxunduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResultListOrgUserInfoVOduixiang>>;

export async function orgUserInfoVoList(
  body: BASE.OrgUserInfoliebiaochaxunduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResultListOrgUserInfoVOduixiang>;

export async function orgUserInfoVoList(
  body: BASE.OrgUserInfoliebiaochaxunduixiang,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResultListOrgUserInfoVOduixiang>(`/app/orgUserInfo/voList`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResultListOrgUserInfoVOduixiang>(`/app/orgUserInfo/voList`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}

/** 获取系统用户VO分页数据 POST /orgUserInfo/voPage */
export async function orgUserInfoVoPage(
  body: BASE.OrgUserInfochaxunduixiang,
  options?: ArgumentsType<typeof api>[1]
): Promise<BASE.IResultIPageOrgUserInfoVOduixiang>;

export async function orgUserInfoVoPage(
  body: BASE.OrgUserInfochaxunduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: true }
): Promise<TupleResponse<BASE.IResultIPageOrgUserInfoVOduixiang>>;

export async function orgUserInfoVoPage(
  body: BASE.OrgUserInfochaxunduixiang,
  options?: ArgumentsType<typeof api>[1] & { tupleResponse: false }
): Promise<BASE.IResultIPageOrgUserInfoVOduixiang>;

export async function orgUserInfoVoPage(
  body: BASE.OrgUserInfochaxunduixiang,
  options?: ArgumentsType<typeof api>[1]
) {
  if (
    (
      options as ArgumentsType<typeof api>[1] & {
        tupleResponse: boolean;
      }
    )?.tupleResponse === true
  ) {
    return api<BASE.IResultIPageOrgUserInfoVOduixiang>(`/app/orgUserInfo/voPage`, {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json'
      },
      data: body,
      ...(options || {}),
      tupleResponse: true
    });
  }

  return api<BASE.IResultIPageOrgUserInfoVOduixiang>(`/app/orgUserInfo/voPage`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  });
}
